package com.seres.data;

public class Index {
//	RISK("Risk",0,17,0.85f,0,17), 
//	TRUST("Trust",0,0,0,0,0), 
//	SHORT_TERM_IMPACT("Short Term Impact",0,0,0,0,0);
	private int indexId;
	private int versionId;
	private String name;
	private float minimumStatusValue;
	private float maximumStatusValue;
	private float resetStatusValue;
	private float initialStatusValue;
	private float thresholdStatusValue;
	
	Index(){
		
	}
	public Index(String name, float minimumStatusValue, float maximumStatusValue, float resetStatusValue, float initialStatusValue, float thresholdStatusValue){
		this.name = name;
		this.minimumStatusValue = minimumStatusValue;
		this.maximumStatusValue = maximumStatusValue;
		this.resetStatusValue = resetStatusValue;
		this.initialStatusValue = initialStatusValue;
		this.thresholdStatusValue = thresholdStatusValue;
	}
	public Index(int versionId, String name, float minimumStatusValue, float maximumStatusValue, float resetStatusValue, float initialStatusValue, float thresholdStatusValue){
		this(name, minimumStatusValue, maximumStatusValue, resetStatusValue, initialStatusValue, thresholdStatusValue);
		setVersionId(versionId);
	}
	public Index(Index index){
		this(index.getVersionId(), index.getName(), index.getMinimumStatusValue(), index.getMaximumStatusValue(), index.getResetStatusValue(), index.getInitialStatusValue(), index.getThresholdStatusValue());
	}
	
	public String toString(){
		return name;
	}
		
	public float getMinimumStatusValue(){
		return minimumStatusValue;
	}
	public float getMaximumStatusValue(){
		return maximumStatusValue;
	}
	public float getResetStatusValue(){
		return resetStatusValue;
	}
	public float getInitialStatusValue(){
		return initialStatusValue;
	}
	public float getThresholdStatusValue(){
		return thresholdStatusValue;
	}

	public int getIndexId() {
		return indexId;
	}

	public void setIndexId(int indexId) {
		this.indexId = indexId;
	}
	public void setVersionId(int versionId) {
		this.versionId = versionId;
	}
	public int getVersionId() {
		return versionId;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	@Override
	public boolean equals(Object obj) {
		return ((Index) obj).getIndexId() == this.getIndexId();
	}
}
